import { createRouter, createWebHistory } from 'vue-router'
import HomeView from '../views/HomeView.vue'

const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path: '/',
      name: 'home',
      component: HomeView,
      redirect: '/home/Index',
      children: [
        {
          path: '/home/Index',
          name: 'index',
          component: () => import('../views/Home/HomeIndex.vue')
        },
        {
          path: '/home/twoIndex',
          name: 'twoIndex',
          component: () => import('../views/Home/TwoIndex.vue')
        },
        {
          path: '/home/threeIndex',
          name: 'threeIndex',
          component: () => import('../views/Home/ThreeIndex.vue')
        },
      ]
    },
     {
          path: '/home/work',
          name: 'work',
          component: () => import('../views/Home/workbench.vue')
        },
  ]
})

export default router
